1. Field of the Invention
The invention relates to a program verifying method, and more particularly to a method for verifying a programmed flash memory.
2. Description of the Related Art
Various electric products need memories for the purposes of storing data or serving as operation buffers. The memories include a random access memory (RAM), a read only memory (ROM), a flash memory, and the like. Data may be conveniently and quickly read from or written into the RAM, but the data will be lost when the power supply is off. So, the RAM is suitable for the purpose of temporarily storing data or serving as an operation buffer. Data has been programmed in the ROM in advance before the ROM is shipped, and data cannot be lost and amended, so the ROM is suitable for the data storage without modifications. Data may be read from or written into the flash memory and the data stored therein can be kept without any power, so the flash memory is suitable for various purposes of data storage.
FIG. 1 is an equivalent circuit diagram showing a flash memory with a virtual ground memory array. The flash memory 100 includes a plurality of memory cells M arranged in an array. Each memory cell M is enabled by its corresponding word line WL. When the flash memory is read or programmed, the corresponding bit line BL and word line WL are enabled according to the memory cell M to be operated. Whether the bit line BL is electrically connected to sense amplifier or grounded is determined through a selection switch, wherein the selection switch and the sense amplifier are not depicted in the drawing.
In the flash memory, the stored content of each memory cell M is determined according to the threshold voltage Vt. FIG. 2 is a graph showing threshold voltage distributions of a memory cell. If the stored content of the memory cell is 0, the memory cell is in the high-threshold distribution region HVt. That is, the threshold voltage thereof has to be greater than the high threshold voltage Vth. If the stored content of the memory cell is 1, the memory cell is in the low-threshold distribution region LVt. That is, the threshold voltage thereof has to be smaller than the low threshold voltage Vtl.
After the data has been written into the flash memory (i.e., after the flash memory has been programmed), it is necessary to perform a verification procedure in order to ensure the correctness of the written data. That is, it is verified that whether the threshold voltage of the memory cell is above Vth or below Vtl according to the stored value of the memory cell. The procedure of reading the memory cell is also similar to the verification procedure. FIG. 3 is an equivalent circuit diagram showing the condition when a memory cell M(k+1,i) is verified or read. The selected word line WLi is enabled, the bit line BL(k+1) is electrically connected to the sense amplifier, and the bit line BL(k+2) is grounded. The bit line BL(k) is electrically coupled to an isolation potential Viso. Ideally, the potential Vd of the bit line BL(k+1) is the same as the potential Viso of BL(k). In the practical application, however, the two voltages may be different owing to the circuit configuration or the manufacturing processes.
FIG. 4 is a schematic table showing values of the applied voltages during the verification and read procedures. When the reading procedure is performed, the voltage Vg of the word line WLi is set to be between the high threshold voltage Vth and the low threshold voltage Vtl, such as 3 volts. The drain voltage Vd of the memory cell M(k+1,i) is set to be 1.6 volts. The sense amplifier detects the drain current Id of the memory cell M(k+1,i) to verify the stored value of the memory cell M(k+1,i). If the drain current Id is high, it means that the memory cell M(k+1,i) is turned on and the stored value thereof is 1. If the drain current Id is 0, it means that the enabled word line WLi cannot turn on the memory cell M(k+1,i) and the stored value is 0.
After the memory cell is programmed and when the verification procedure is performed, the voltage Vg applied to the word line WLi is set to be 4.2 volts, and the drain voltage Vd of the memory cell M(k+1,i) is set to be 1.6 volts. The sense amplifier detects the drain current Id of the memory cell M(k+1,i) to verify the stored value of the memory cell M(k+1,i). If the drain current Id detected by the sense amplifier is 0, it means that the enabled word line WLi cannot turn on the memory cell M(k+1,i). So, the threshold voltage of the memory cell M(k+1,i) is greater than the voltage Vth, and the memory cell M(k+1,i) is in the high-threshold distribution region, which means that the written data is correct: otherwise, it means that the threshold voltage of the memory cell M(k+1,i) is not high enough, and the memory cell has to be re-programmed so that the data may be written thereto.
However, the leakage current existing in the verification procedure makes the verification result not precise enough. As shown in FIG. 3, the drain current Id actually includes the sum of the current Icl flowing through the memory cell M(k+1,i) and the leakage current lleak. The leakage current lleak is determined by the voltage of the word line WLi and the difference between the drain voltage Vd of the memory cell M(k+1,i) and the isolation voltage Viso. When the verification procedure is performed, the voltage of the word line WLi is higher. So, once the drain voltage Vd and the isolation voltage Viso are different, the generated leakage current is larger, and the verification precision will be influenced.